import http from './http'
// 登录
const login = (params) => {
    return http.post('/users/login',params)
}
// 注册
const enroll = (enrl)=>{
    return http.post('/users/register',enrl)
}

// 添加
const adds = (increase)=>{
    return http.post('/profiles/add',increase)
}

// 获取所有数据
const fetch = (feh)=>{
    return http.get('/profiles',feh)
}

// 删除
const del=(dte)=>{
    return http.delete(`/profiles/delete/${dte}`)
}

// 修改
const edit = (dit)=>{
    return http.post(`/profiles/edit/${dit.id}`,dit)
}

export {login,enroll,adds,fetch,del,edit}